function fn() {
    document.documentElement.style.fontSize=document.documentElement.clientWidth*50/1920+'px';
}
window.onresize=fn;
document.addEventListener('DOMContextLoaded',fn,false)